If we want to visualize several timesteps of our 2D simulation simultaneously,
we run into the problem that our monitor is actually 2D. A solution might be to
render the 3D (2D plus time) structure using basic volume visualization
methods. This is the idea of time slices.

The circular buffer described in section \ref{sec:datasetrepresentation} takes
care of storing the various time slices and updating them when a time step has
passed. For alpha blending reasons, we start rendering the `oldest' slice for a
low value of $z$ (i.e. far away). Progressively, more recent time slices are
rendered for higher $z$-values. The most recent slice is drawn on top. Controls
are added for the user to translate and rotate the visualized 3D-structure.

If we would not use alpha blending, the result of this procedure would just be
a stack of opaque slices. We define two ways in which the alpha value of drawn
elements is modified. The global alpha value $\alpha_\mathrm{global}$ applies
to all drawn elements. In addition to that, each visualizer has its own local
alpha value $\alpha_\mathrm{local}$ which is based on the value of a scalar
dataset on the point where the visualizer is drawn. Analogous to the scalar
dataset of the colormap, a visualizer can be linked to each of the scalar
datasets for alpha modification through user interaction.
The value $\alpha_\mathrm{local}$ is determined such that it is 1 where the
alpha dataset has its maximum value, and 0 where it has its minimum value.
Values inbetween are linearly scaled, similar to the autoscaling of color
vector indices. When determing the minimum and the maximum value, the values in
all the drawn slices are considered.

The alpha value which is actually used to draw elements is simply the
multiplication of $\alpha_\mathrm{global}$ and $\alpha_\mathrm{local}$. Since
this method can yield visualizations which are pretty dark, we allowed
$\alpha_\mathrm{global}$ to be set higher than 1. If the product of
$\alpha_\mathrm{global}$ and $\alpha_\mathrm{local}$ exceeds 1, it is set to 1.
Values $\mathrm{min}_\mathrm{data}$ and $\mathrm{max}_\mathrm{data}$ are
determined by look at the values in \textit{all} the slices. Figure
\ref{fig:time_passes} shows how our volume visualization shows the passing of
time. Note that alpha blending has been disabled in this figure.

\begin{figure}[ht]
  \begin{center}
    \begin{subfigure}[b]{0.3\textwidth}
      \centering
      \includegraphics[trim=0mm 0mm 0mm 0mm,clip,width=\textwidth]{./images/time_goes_by1}
      \caption{$t_1$}
    \end{subfigure}
    \begin{subfigure}[b]{0.3\textwidth}
      \centering
      \includegraphics[trim=0mm 2mm 0mm 0mm,clip,width=\textwidth]{./images/time_goes_by2}
      \caption{$t_2$}
    \end{subfigure}
    \begin{subfigure}[b]{0.3\textwidth}
      \centering
      \includegraphics[trim=0mm 2mm 0mm 0mm,clip,width=\textwidth]{./images/time_goes_by3}
      \caption{$t_3$}
    \end{subfigure}
  \end{center}
  \caption{Three successive renderings of our 3D structure. As times passes
    ($t_1 < t_2 < t_3$) fluid density levels traverse from the front
    (bottom) plane to the back (top) plane. Note that alpha blending has been
    disabled, resulting in opaque slices.}
  \label{fig:time_passes}
\end{figure}


